



var htmlWebpackPlugin = require('html-webpack-plugin')

module.exports ={
    entry:'./src/index.js',
    output:{
        filename:'bundle.js'
    },
    plugins:[
        //所有webpack插件的配置节点
        new htmlWebpackPlugin ({
        template:'./src/index.html',
            filename:'index.html'
        })
    ],
    module:{
        rules: [
            {test:/\.css$/,use:['style-loader','css-loader']},

            {test:/\.less$/,use:['style-loader','css-loader','less-loader']},

            {test:/\.scss$/,use:['style-loader','css-loader','sass-loader']},

            { test:/\.vue$/,use:'vue-loader'},

            {test:/\.ttf$/,use:'url-loader'},
        ]
    }
};